﻿<%@ Page CodeFileBaseClass="AliCMS.Lib.SystemPageBase" %>
<ali:Get ID="Module" Object="Module" Operation="Get(Request.QueryString['Namespace'])" />
<ali:Get ID="Object" Object="Module.Object" Operation="Get(Request.QueryString['Namespace'], Convert.ToInt32(Request.QueryString['ID']))" />
<section data-page="module_object_edit" data-title="编辑对象" data-lang="<%=ContentLang%>" data-namespace="<%=Module[Namespace]%>" data-id="<%=Request.QueryString["ID"]%>">
	<dl class="path1">
		<dt><span>您的位置：</span><a href="../list.aspx" target="ali-navtab">模块列表</a> → <a href="list.aspx?Lang=<%=ContentLang%>&amp;Namespace=<%=Request.QueryString["Namespace"]%>" target="ali-navtab"><b class="<%=ContentLang%>Font"><%=Module[Label]%></b>模块的对象列表</a> → <b class="<%=ContentLang%>Font"><%=Object[Label]%></b></dt>
		<dd>
			<select data-class="<%=ContentLang%>Font" data-ali-widget="combo">
				<ali:List Object="Language" Source="Manager.Languages">
					<ali:Record>
						<%If Convert.ToString(Ab) == ContentLang%>
							<option value="<%=Ab%>" selected><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%Else%>
							<option value="<%=Ab%>"><%=[AliCMS.SystemModule.Alias.Language.Name + PageLang]%></option>
						<%EndIf%>
					</ali:Record>
				</ali:List>
			</select>
		</dd>
	</dl>
	<form action="" class="post">
		<div class="post-body">
			<div class="ali-tabs" data-event="click">
				<div class="ali-tabs-header">
					<div class="ali-tabs-nav-container">
						<ul>
							<li class="ali-active"><a>编辑</a></li>
							<li><a href="operation/list.aspx?Lang=<%=ContentLang%>&amp;Namespace=<%=Request.QueryString["Namespace"]%>&amp;ObjectID=<%=Request.QueryString["ID"]%>" target="ali-navtab">操作列表</a></li>
							<li><a href="operation/add.aspx?Lang=<%=ContentLang%>&amp;Namespace=<%=Request.QueryString["Namespace"]%>&amp;ObjectID=<%=Request.QueryString["ID"]%>" target="ali-navtab">添加操作</a></li>
							<li><a href="property/list.aspx?Lang=<%=ContentLang%>&amp;Namespace=<%=Request.QueryString["Namespace"]%>&amp;ObjectID=<%=Request.QueryString["ID"]%>" target="ali-navtab">属性列表</a></li>
							<li><a href="property/add.aspx?Lang=<%=ContentLang%>&amp;Namespace=<%=Request.QueryString["Namespace"]%>&amp;ObjectID=<%=Request.QueryString["ID"]%>" target="ali-navtab">添加属性</a></li>
						</ul>				
					</div>
				</div>
				<div class="ali-tabs-body">
					<div class="ali-tabs-panel">
						<table class="post-table margin2">
							<tr>
								<th>父对象：</th>
								<td>
									<select name="ParentID" data-class="<%=ContentLang%>Font" data-ali-widget="combo" data-tree="true" data-root="">
										<option value="" data-item="" data-parent="">未指定</option>
										<ali:Tree Object="Module.Object" Condition="Namespace=Request.QueryString['Namespace']">
											<ali:Record>
												<%If Guid.Equals(ID, Object[ParentID])%>
													<option value="<%=ID%>" data-item="<%=InnerID%>" data-parent="<%=ParentInnerID%>" selected><%=Name%></option>
												<%Else%>
													<option value="<%=ID%>" data-item="<%=InnerID%>" data-parent="<%=ParentInnerID%>"><%=Name%></option>
												<%EndIf%>
												<%=ChildRecords%>
											</ali:Record>
										</ali:Tree>
									</select>
								</td>
							</tr>
							<tr>
								<th>名称：</th>
								<td><input type="text" name="Label" value="<%=Object[Label]%>" size="30" maxlength="50" class="ali-input <%=ContentLang%>Font"></td>
							</tr>
							<tr>
								<th>别名：</th>
								<td><input type="text" name="Name" value="<%=Object[Name]%>" size="30" maxlength="50" class="ali-input"></td>
							</tr>
							<tr>
								<th>表名称：</th>
								<td><input type="text" name="TableName" value="<%=Object[TableName]%>" size="30" maxlength="50" class="ali-input"></td>
							</tr>
							<tr>
								<th>备注：</th>
								<td><textarea rows="5" cols="60" name="Memo" class="ali-input"><%=HttpUtility.HtmlEncode(Convert.ToString(Object[Memo]))%></textarea></td>
							</tr>
						</table>
					</div>
				</div>
				<div class="ali-tabs-bottom"><b></b></div>
			</div>
		</div>
		<div class="post-footer"><button type="submit" class="ali-button">保 存</button></div>
	</form>
</section>